<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="https://unpkg.com/vue@next"></script>
</head>
<body>
    <div id="app">
        <anchored-heading :level='2'>Hello World2</anchored-heading>
    </div>

    <script>
        const AppComp = {

        }

        const AnchoredHeadingComp = {
            props:{
                level:{
                    type:Number,
                    required:true
                }
            },
            render(_h) {
                const { h } = Vue
                return h(
                    'h'+this.level,
                    {},
                    this.$slots.default()
                )
            },
        }

        const app = Vue.createApp(AppComp)
        app.component("anchored-heading",AnchoredHeadingComp)
        const vm = app.mount('#app')
    </script>
</body>
</html>